cmake_minimum_required(VERSION 3.22)
project(pktbuilder)
set(CMAKE_CXX_STANDARD 20)
include_directories(include)
add_library(pktbuilder src/Ethernet.cpp src/DNS.cpp src/addresses.cpp src/Layer.cpp src/IPv4.cpp src/ICMP.cpp src/checksum.cpp src/TCP.cpp src/UDP.cpp src/utils.cpp src/pktbuilder.cpp)
if (WIN32)
    target_link_libraries(pktbuilder iphlpapi)
endif()
include(CTest)
if (BUILD_TESTING)
    add_subdirectory(tests)
endif()